package ex8_2;
public class Demon_2 {
	
		public static void main(String[] args) {
		     SimpleThread sThread1=new SimpleThread("a Thread");
		     SimpleThread sThread2=new SimpleThread("b Thread ");
		     SimpleThread sThread3=new SimpleThread(" go to heife");
		    //实现了Runnable接口对象
		     
		     
		     Thread t1=new Thread(sThread1);
		     Thread t2=new Thread(sThread2);
		     Thread t3=new Thread(sThread3);
		     //1,2,3才是线程对象
		     t1.start();
		     t2.start();
		     t3.start();
		     
		     
		    /**
		     * 1.实现Runnable 接口
		     * 2.重写Runnable接口中的run()方法
		     * 3.实例化一个实现了Runnable接口的实例对象，如sThread1
		     * 4.用这个实例对象作为Thread构造方法的实参，来创建Thread实例对象
		     * 5.调用Thread实例对象的start()方法启动线程
		     */
		     
		     
		     
		     
			}

	}


